-- background: 25947 from stack: in -- bmap block id: 26165 -- flags: 0000 -- background id: 0 -- name: Teacher Details tabs ----- HyperTalk script ----- on openBackground global checkLoc1,checkLoc2,checkLoc3,teacherName put 1 into checkLoc1 put 1 into checkLoc2 put 1 into checkLoc3 if (card field "First Name" of first card of this bg is empty) AND (card field "Last Name" of first card of this bg is empty) then put empty into teacherName end if end openBackground on doMenu menuItem lock screen if menuItem contains "About" then resetFields restoreMenuBar go to card "Teacher Details" of background "About" unlock screen with zoom close else if menuItem is "Home" then resetFields restoreMenuBar go home else if menuItem contains "Quit" then resetFields restoreMenuBar false go to card "Mac School® Shell" unlock screen with zoom close end if end doMenu on resetFields lock screen set cursor to watch push card go to first card of this background -- Personal tab repeat with fieldNum = 1 to the number of card fields put empty into card field fieldNum end repeat click at the loc of button "Male" put "NA" into card field "Home Language" put "NA" into card field "Ethnic Category" go to next card -- Miscellaneous tab repeat with fieldNum = 1 to the number of card fields put empty into card field fieldNum end repeat repeat with buttonNum = 1 to the number of buttons set hilite of button buttonNum to false end repeat go to next card -- Department tab put "NA" into card field "Department" put "Unassigned" into card field "Room #" go to next card -- Scheduler course preferences tab repeat with lineNum = 1 to 30 put "0" into line lineNum of card field "Course Preference" end repeat put "1" into card field "Maximum" go to next card -- Scheduler room preferences tab put "Any Room" into card field "Rooms" pop card unlock screen end resetFields -- part 1 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=31 top=37 right=58 bottom=140 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: TD Personal ----- HyperTalk script ----- on mouseUp go to card short name of target end mouseUp -- part 2 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=143 top=37 right=58 bottom=254 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: TD Miscellaneous ----- HyperTalk script ----- on mouseUp global teacherName if short name of this card is not short name of me then lock screen go to card short name of target if teacherName is not empty then put teacherName into field "teacher" else put "name not defined" into field "teacher" unlock screen tabKey end if end mouseUp -- part 3 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=257 top=37 right=58 bottom=366 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: TD Department ----- HyperTalk script ----- on mouseUp global teacherName if short name of this card is not short name of me then lock screen go to card short name of target if teacherName is not empty then put teacherName into field "teacher" else put "name not defined" into field "teacher" set the scroll of card field "Rooms" to 0 unlock screen end if end mouseUp -- part 4 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=369 top=37 right=58 bottom=480 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: TD Scheduler ----- HyperTalk script ----- on mouseUp global teacherName if short name of this card is not short name of me then lock screen go to card short name of target if teacherName is not empty then put teacherName into field "teacher" else put "name not defined" into field "teacher" unlock screen end if end mouseUp -- part 5 (button) -- low flags: 00 -- high flags: A003 -- rect: left=147 top=303 right=324 bottom=250 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Cancel ----- HyperTalk script ----- on mouseUp pop card end mouseUp -- part 6 (button) -- low flags: 00 -- high flags: A003 -- rect: left=267 top=303 right=325 bottom=370 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Done ----- HyperTalk script ----- on mouseUp lock screen resetFields pop card unlock screen end mouseUp -- part 7 (field) -- low flags: 01 -- high flags: 0000 -- rect: left=85 top=63 right=81 bottom=487 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Teacher